package com.dd.cloud.user.service.paynotice.promode;

import java.lang.annotation.Annotation;

/**
 * 此类的目的是作为策略模式的参数 有多个参数,回调处理类map 的key 只要类的值一致即可
 */
public class NoticeTypeImpl implements NoticeType{
    String source;
    String proType;
    public NoticeTypeImpl(String sta, String proType) {
        this.source = sta;
        this.proType = proType;
    }

    @Override
    public String source() {
        return null;
    }

    @Override
    public String proType() {
        return null;
    }

    @Override
    public Class<? extends Annotation> annotationType() {
        return null;
    }

    @Override
    public boolean equals(Object obj) {
        if (!(obj instanceof NoticeType)) {
            return false;
        }
        NoticeType other = (NoticeType) obj;
        return source.equals(other.source()) && proType.equals(other.proType());
    }

    @Override
    public int hashCode() {
        int hashCode = 0;
        hashCode += (127 * "source".hashCode()) ^ source.hashCode();
        hashCode += (127 * "proType".hashCode()) ^ proType.hashCode();
        return hashCode;
    }

}
